The present exemplary embodiments are directed to methods for image segmentation to produce a mixed raster content (“MRC”) image with multiple extracted constant color areas (“MECCA”). MRC modeling is a powerful image representation concept in achieving high compression ratios while maintaining high-constructed image quality. MECCA modeling has the further advantages of relatively undemanding decomposition requirements and inherent text enhancement and noise reduction features. The MECCA model contains one background layer, N foreground layers, and N mask layers where N is a non-negative integer. While the background layer can be a contone bitmap, the foreground layers are restricted to constant colors. U.S. Ser. No. 10/866,850 entitled “Method for Image Segmentation to Identify Regions with Constant Foreground Color”, filed Jun. 14, 2003 hereby incorporated by reference in its entirety, details a relevant MECCA modeling method.
To generate MRC/MECCA representation for an image, segmentation is required. The segmentation algorithm generally consists of four steps, namely object extraction, object selection, color clustering, and result generation. In the first step, text and other objects are extracted from the image. Next, the objects are tested for color constancy and other features to decide if they should be represented in the foreground layers. The objects that are chosen are then clustered in color space as the third step. The image is finally segmented such that each foreground layer codes the objects from the same color cluster.
Windowing is another concept in document image segmentation. Windowing partitions the page into different regions that are separated by background borders. Windowing first identifies the page background that separates different text objects and windows. The windows are classified as pictorial and graphical (called “composite”). The graphical windows are further recursively processed. The local background of a graphical window is detected. The text and windows (within a window) are separated by the local background. The windows (within a window) are classified. The process repeats until all the objects are separated.
There is a need for a windowing that can be applied as a part of MRC/MECCA segmentation. It extracts text and other details as the objects, which are the candidates that are to be coded in foreground layers.
Page background detection is typically a first step for scanned document image segmentation. The detected background can then be applied for separating different objects in the page including text characters, pictures and graphics. Page background detection may also be useful for applications like background enhancement. Most existing page background detection methods are based on global thresholding. Specifically, a threshold is first determined using some statistics extracted from a global histogram of the pixel intensities. The threshold is then applied to every pixel on the page. The above approach typically generates reasonable results, but it may fail in the text regions, and other regions where the background neighbors dark objects. Quite often, the background in the text (and darker) regions has a different statistic distribution than the one in the open white areas. It tends to be darker for many reasons, e.g. ICE (Integrated Cavity Effect) and JPEG ringing artifacts (some scanned images are lightly JPEG compressed to reduce file size and/or bandwidth, the ringing introduced may not be visible as the compression is light, but could be strong enough to change the page background detection results). Errors in background detection could be harmless for applications like background enhancement, but may introduce severe artifacts for other applications such as to segment for the MRC/MECCA model. If the threshold is globally lowered (hence more areas will be detected as background), the problem can be avoided. However, there is a risk to mis-classify the light non-background arrears, such as picture regions, as background. Local thresholding methods exist for separating text and background. They rely on local statistics to establish threshold. They can effectively extract text and other small details and thus are suitable for applications like OCR. But they are not able to find large objects like pictorial windows and are generally not applicable for page background detection. For example, for text on a color background, they typically classify them as “text” and “background”, while in our case, both should be classified as “non-page background”. In addition, local thresholding methods typically demand much more computation.
The segmenting of the data into either background or text is important because different compression algorithms are much more efficient for different kinds of images. For example, JPEG is a more efficient compression algorithm for pictures while other algorithms are especially designed for binary images like text. Using different compression algorithms for different portions of the scanned image data provides the advantage of a high compression ratio for the data with high quality image reconstruction.
Accordingly, there is a need for better segmenting of scanned image data that can more accurately identify background and text data within the scanned image data.